Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add check to prevent the Parsec service from running as root #219

Merged
merged 1 commit into from
Aug 18, 2020

Conversation

joechrisellis
Copy link
Contributor

This commit introduces a guard at the top of main to ensure that
Parsec is not being run as root. Disallowing the Parsec service from
running as root reduces attack surface in line with the principle of
least privilege.

This behaviour can be overridden by setting the PARSEC_ALLOW_ROOT
environment variable.

Signed-off-by: Joe Ellis joe.ellis@arm.com

src/bin/main.rs Outdated Show resolved Hide resolved
@joechrisellis joechrisellis force-pushed the not_root_check branch 5 times, most recently from 0c854f6 to 4e9eaa4 Compare August 13, 2020 13:33
Copy link
Member

@ionut-arm ionut-arm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! I don't know why we didn't implement this earlier.

config.toml Outdated Show resolved Hide resolved
src/bin/main.rs Outdated Show resolved Hide resolved
This commit introduces a guard at the top of `main` to ensure that
Parsec is not being run as root. Disallowing the Parsec service from
running as root reduces attack surface in line with the principle of
least privilege.

This behaviour can be overridden by setting the `PARSEC_ALLOW_ROOT`
environment variable.

Signed-off-by: Joe Ellis <joe.ellis@arm.com>
Copy link
Member

@hug-dev hug-dev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great addition!

@hug-dev hug-dev merged commit 5832e96 into parallaxsecond:master Aug 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants